home *** CD-ROM | disk | FTP | other *** search
/ Pascal Super Library / Pascal Super Library (CW International)(1997).bin / STRINGS / PACKAGE6 / INTVALUE.DOC < prev    next >
Text File  |  1990-07-25  |  1KB  |  35 lines

  1. -----------------------------------------------------------------------------
  2. IntegerValue
  3. -----------------------------------------------------------------------------
  4.  
  5. declaration:    function IntegerValue (    AString:
  6.                                              TypeString):
  7.                                                integer;
  8.  
  9. purpose:        To convert a string into an integer equivalent
  10.  
  11. precondition:   AString is filled with numbers only
  12.  
  13. postcondition:  IntegerValue is a positive/negative integer
  14.                 IntegerValue is set to zero if there are any
  15.                 characters in AString
  16.  
  17. special cases:  none
  18.  
  19. example:        var
  20.                   AString:
  21.                     TypeString;
  22.  
  23.                 begin
  24.                   .
  25.                   .
  26.                   .
  27.                   ReadLnString (AString, LastKey);
  28.                   writeln (output, IntegerValue (AString));
  29.                   .
  30.                   .
  31.                   .
  32.                 end
  33.  
  34. --------------------------------------------------------------------------------
  35.